#ifndef __CM_NAT_JINGLE_H__
#define __CM_NAT_JINGLE_H__

#include "clientbase.h"
#include "iqhandler.h"

namespace cm_nat
{
	using namespace cm_xmpp;

    class JingleListener
    {
    public:
        virtual void onJingleTag(const Tag* p_tag) = 0;
    };

    //IQ handler handle Jingle Extension
    //Jingle register itself to gloox in consturct function
    //when object created
    class Jingle : public IqHandler
    {
    public:
        Jingle( ClientBase* parent, JingleListener* listener);

        virtual ~Jingle();

        // reimplemented from IqHandler.
        virtual bool handleIq( const IQ& iq );

        // reimplemented from IqHandler.
        virtual void handleIqID( const IQ& iq, int context );

    protected:
        ClientBase* m_parent;
        JingleListener* m_listener;
    };
}

#endif